Previously written by: Lynn McKaig and Ehric Ho, TGS Systems
Updated for 2.6.1 by: The Tech Support Team, Pictorius Incorporated
Note: Using pictures and PICT resources can take up a lot of memory - to use this example with certain PICT resources it will probably be necessary to increase the memory partition of the Classic Interpreter. Also keep this in mind when you compile your application.
Contents: Scroll Pict.pgs
Scroll Pict.ReadMe
Needs Prograph Extensions:
The default configuration of your 'Prograph Extensions' folder.
Needs Libraries to Compile:
SCLibrary 2.6
Library 2.6
New Classes:
Pict File - Subclass of Canvas that draws a picture from a PICT file.
Pict rsrc - Subclass of Canvas that draws a picture from a PICT resource.
New Methods:
Read PICT File - A universal method that reads a picture from a PICT file
Description
-----------
This example demonstrates how to read a picture from a PICT file. Our technical support department is asked how to do this surprisingly often. The universal method "Open File" opens a file, reads a picture from it, and displays the picture in a window.
It also demonstrates how to draw a picture with scroll bars. The class "Scroll Pict" does most of the work, the classes "PICT File" and "PICT rsrc" are refinements of "Scroll Pict" which display pictures from files and resources respectively.